package com.ruoyi.yun.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.yun.mapper.YunCoufigVoiceconfigMapper;
import com.ruoyi.yun.domain.YunCoufigVoiceconfig;
import com.ruoyi.yun.service.IYunCoufigVoiceconfigService;

/**
 * 语音自动播报设置Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-10-24
 */
@Service
public class YunCoufigVoiceconfigServiceImpl implements IYunCoufigVoiceconfigService 
{
    @Autowired
    private YunCoufigVoiceconfigMapper yunCoufigVoiceconfigMapper;

    /**
     * 查询语音自动播报设置
     * 
     * @param id 语音自动播报设置主键
     * @return 语音自动播报设置
     */
    @Override
    public YunCoufigVoiceconfig selectYunCoufigVoiceconfigById(Long id)
    {
        return yunCoufigVoiceconfigMapper.selectYunCoufigVoiceconfigById(id);
    }

    /**
     * 查询语音自动播报设置列表
     * 
     * @param yunCoufigVoiceconfig 语音自动播报设置
     * @return 语音自动播报设置
     */
    @Override
    public List<YunCoufigVoiceconfig> selectYunCoufigVoiceconfigList(YunCoufigVoiceconfig yunCoufigVoiceconfig)
    {
        return yunCoufigVoiceconfigMapper.selectYunCoufigVoiceconfigList(yunCoufigVoiceconfig);
    }

    /**
     * 新增语音自动播报设置
     * 
     * @param yunCoufigVoiceconfig 语音自动播报设置
     * @return 结果
     */
    @Override
    public int insertYunCoufigVoiceconfig(YunCoufigVoiceconfig yunCoufigVoiceconfig)
    {
        return yunCoufigVoiceconfigMapper.insertYunCoufigVoiceconfig(yunCoufigVoiceconfig);
    }

    /**
     * 修改语音自动播报设置
     * 
     * @param yunCoufigVoiceconfig 语音自动播报设置
     * @return 结果
     */
    @Override
    public int updateYunCoufigVoiceconfig(YunCoufigVoiceconfig yunCoufigVoiceconfig)
    {
        yunCoufigVoiceconfig.setUpdateTime(DateUtils.getNowDate());
        return yunCoufigVoiceconfigMapper.updateYunCoufigVoiceconfig(yunCoufigVoiceconfig);
    }

    /**
     * 批量删除语音自动播报设置
     * 
     * @param ids 需要删除的语音自动播报设置主键
     * @return 结果
     */
    @Override
    public int deleteYunCoufigVoiceconfigByIds(Long[] ids)
    {
        return yunCoufigVoiceconfigMapper.deleteYunCoufigVoiceconfigByIds(ids);
    }

    /**
     * 删除语音自动播报设置信息
     * 
     * @param id 语音自动播报设置主键
     * @return 结果
     */
    @Override
    public int deleteYunCoufigVoiceconfigById(Long id)
    {
        return yunCoufigVoiceconfigMapper.deleteYunCoufigVoiceconfigById(id);
    }
}
